package com.hbx.mapper;

import com.hbx.model.Menu;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author hbx
 * @since 2021-11-26
 */
@Mapper
public interface MenuMapper extends BaseMapper<Menu> {
    /**
     * 根据用户id查询菜单列表
     * @param userId
     * @return
     */
    List<Menu> selectMenuByUserId(@Param("userId") Integer userId);

    /**
     * 根据用户id查询三级菜单
     * @param userId
     * @return
     */
    List<Menu> selectMenuRouteByUserId(@Param("userId") Integer userId);
}
